import React, { useEffect, useState } from "react";
import logo from "./logo.svg";
import "./App.css";
import { ProjectList } from "screens/project-list";
import { Login } from "screens/login/login";

function App() {
  const [isLoginBoolean, setIsLogin] = useState(false);

  function login() {
    setIsLogin(true);
  }

  function logout() {
    setIsLogin(false);
  }

  useEffect(() => {
    // console.log('hello world');
  });

  return isLoginBoolean ? (
    <ProjectList logout={logout} />
  ) : (
    <Login login={login} />
  );
}

export default App;
